<%
=begin
apps: prometheus-operator
platforms: kubernetes, tanzu-application-catalog
id: customize_scrape_configurations
title: Customize scrape configurations
category: configuration
weight: 100
=end %>

It is possible to inject externally managed scrape configurations via a Secret by setting *prometheus.additionalScrapeConfigs.enabled* to *true* and *prometheus.additionalScrapeConfigs.type* to *external*. The secret must exist in the same namespace which the kube-prometheus will be deployed into. Set the secret name using the parameter *prometheus.additionalScrapeConfigs.external.name*, and the key containing the additional scrape configuration using the *prometheus.additionalScrapeConfigs.external.key*.

For instance, if you created a secret named *kube-prometheus-prometheus-scrape-config* and it contains a file named *additional-scrape-configs.yaml*, use the parameters below:

```
prometheus.additionalScrapeConfigs.enabled=true
prometheus.additionalScrapeConfigs.type=external
prometheus.additionalScrapeConfigs.external.name=kube-prometheus-prometheus-scrape-config
prometheus.additionalScrapeConfigs.external.key=additional-scrape-configs.yaml
```

It is also possible to define scrape configurations to be managed by the Helm chart by setting *prometheus.additionalScrapeConfigs.enabled* to *true* and *prometheus.additionalScrapeConfigs.type* to *internal*. You can then use *prometheus.additionalScrapeConfigs.internal.jobList* to define a list of additional scrape jobs for Prometheus, as shown below:

```
prometheus.additionalScrapeConfigs.enabled=true
prometheus.additionalScrapeConfigs.type=internal
prometheus.additionalScrapeConfigs.internal.jobList=
      - job_name: 'opentelemetry-collector'
        # metrics_path defaults to '/metrics'
        # scheme defaults to 'http'.
        static_configs:
          - targets: ['opentelemetry-collector:8889']
```

For more information, see the [additional scrape configuration documentation](https://github.com/prometheus-operator/prometheus-operator/blob/master/Documentation/additional-scrape-config.md).
